<!DOCTYPE html>
<html lang="zh-CN">
<head>
    <meta charset="UTF-8">
    <meta name="viewport" content="width=device-width, initial-scale=1.0">
    <title>HorinJiang官方个人网站</title>
    <link rel="Shortcut Icon" href="./logo.ico" type="image/x-icon" />
    <style>
        body {
            font-family: Arial, sans-serif;
            margin: 0;
            padding: 0;
            background-color: #f1f1f1;
        }
        .header {
            background-color: #000;
            color: #fff;
            display: flex;
            justify-content: center; /* 水平居中 */
            align-items: center;
            padding: 20px;
            max-width: 1200px;
            margin: 0 auto;
        }
        .header .profile {
            display: flex;
            align-items: center; /* 垂直居中 */
        }
        .header .profile img {
            border-radius: 50%;
            width: 75px;
            height: 75px;
            margin-right: 20px;
        }
        .header .info {
            display: flex;
            flex-direction: column;
        }
        .header h1 {
            margin: 0;
        }
        .header p {
            margin: 0;
            color: #aaa;
        }
        .header .signature {
            margin-top: 10px;
            font-style: italic;
        }
        .blog {
            margin: 20px;
            padding: 20px;
            background-color: #fff;
            max-width: 1200px;
            margin: 0 auto;
        }
        .blog h2 {
            margin: 20px 0 5px 0;
        }
        .blog time {
            color: #aaa; /* 低亮显示 */
            font-size: 0.8em; /* 小号字体 */
            margin-bottom: 20px;
        }
        .blog img {
            width: 100%;
            max-width: 300px;
            height: auto;
            margin-top: 20px;
        }
.blog-post {
    margin-bottom: 30px; /* 增加博客之间的间隔 */
}

        .lightbox {
            display: none;
            position: fixed;
            top: 0;
            left: 0;
            width: 100%;
            height: 100%;
            background-color: rgba(0, 0, 0, 0.8);
            z-index: 1000;
        }
        .lightbox img {
            max-width: 90%;
            max-height: 90%;
            margin: 5% auto;
            display: block;
        }




        .pagination {
            display: flex;
            justify-content: center;
            margin: 20px 0;
        }

        .pagination button {
            background-color: #f1f1f1;
            border: 1px solid #ddd;
            color: black;
            padding: 5px 10px;
            text-decoration: none;
            border-radius: 5px;
            cursor: pointer;
            margin: 0 5px;
        }

        .pagination button.active {
            background-color: #4CAF50;
            color: white;
        }

.footer {
            background-color: #f1f1f1;
            color: #333;
            text-align: center;
            padding: 20px;
            margin-top: 20px;
            border-top: 1px solid #ddd;
        }


.vip-badge {
            display: inline-block;
            width: 20px;
            height: 20px;
            background-color: gold;
            border-radius: 50%;
            text-align: center;
            line-height: 20px;
            color: white;
            font-weight: bold;
            margin-right: 5px;
            /* 添加光环效果 */
            box-shadow: 0 0 10px rgba(255, 255, 255, 1), 0 0 20px rgba(255, 255, 255, 0.8), 0 0 30px rgba(255, 255, 255, 0.5);
            /* 添加动态光环动画 */
            animation: glow 5s infinite alternate;
        }

        @keyframes glow {
            0% {
                box-shadow: 0 0 10px rgba(255, 255, 255, 1), 0 0 20px rgba(255, 255, 255, 0.8), 0 0 30px rgba(255, 255, 255, 0.5);
            }
            100% {
                box-shadow: 0 0 10px rgba(255, 255, 255, 0.5), 0 0 20px rgba(255, 255, 255, 0.3), 0 0 30px rgba(255, 255, 255, 0.1);
            }
        }
    </style>
</head>
<body>
    <div class="header">
        <div class="profile">
            <img src="./TX.jpg" alt="头像">
        </div>
        <div class="info">
            <h1>HorinJiang</h1>
            <div>
                <span class="vip-badge">V</span>
                <span>7号时空首席执行官</span>
            </div>
            <p class="signature" id="signature"></p>
        </div>
    </div>

<script>
    // 创建一个包含多个签名的数组
    const signatures = [
        "请问一下这里有没有卖半岛铁盒",
    ];

    // 从数组中随机选择一个签名
    const randomIndex = Math.floor(Math.random() * signatures.length);
    const randomSignature = signatures[randomIndex];

    // 将选中的签名赋值给 HTML 中的个性签名元素
    document.getElementById("signature").textContent = randomSignature;
</script>

    <div class="blog">
        <!-- 博客内容将通过JavaScript动态插入 -->
    </div>

 <div class="pagination">
        <!-- 分页按钮将通过JavaScript动态插入 -->
    </div>

 <div class="footer">
        &copy; 2024 © HorinJiang. All rights reserved. | 临时博客页  | 开源 
    </div>


    <script>
        // 博客数据数组
        const blogPosts = [
             {
                title: 'HelloWorld',
                date: '2023/04/15 08:51',
                content: '第一组数据必须是HelloWorld！'
            },
         

        ];

        // 分页配置
        const pageSize = 6; // 每页显示的博客文章数量
        let currentPage = 1; // 当前页码

        // 获取博客容器和分页容器
        const blogContainer = document.querySelector('.blog');
        const paginationContainer = document.querySelector('.pagination');

        // 显示博客文章和分页按钮的函数
        function displayPosts() {
            // 计算总页数
            const totalPages = Math.ceil(blogPosts.length / pageSize);

            // 清空博客容器
            blogContainer.innerHTML = '';

            // 获取当前页的数据子集
            const start = (currentPage - 1) * pageSize;
            const end = start + pageSize;
            const currentPosts = blogPosts.slice(start, end);

            // 创建并插入当前页的博客文章
            currentPosts.forEach(post => {
                const blogPost = document.createElement('div');
                blogPost.className = 'blog-post';
                blogPost.innerHTML = `
                    <h2>${post.title}</h2>
                    <time datetime="${post.date}">${post.date}</time>
                    <p>${post.content}</p>
                `;
                blogContainer.appendChild(blogPost);
            });

            // 清空分页容器
            paginationContainer.innerHTML = '';

            // 创建并插入分页按钮
            for (let i = 1; i <= totalPages; i++) {
                const pageBtn = document.createElement('button');
                pageBtn.textContent = i;
                pageBtn.onclick = function() {
                    currentPage = i;
                    displayPosts();
                };
                if (i === currentPage) {
                    pageBtn.classList.add('active');
                }
                paginationContainer.appendChild(pageBtn);
            }
        }

        // 初始化博客文章和分页按钮的显示
        displayPosts();
    </script>
</body>
</html>